package com.yupi.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.yupi.model.domain.Team;
import com.yupi.model.domain.Userinfo;
import com.yupi.model.dto.TeamJoinDTO;
import com.yupi.model.dto.TeamQueryDTO;
import com.yupi.model.dto.TeamQuitDTO;
import com.yupi.model.dto.TeamUpdateDTO;
import com.yupi.model.vo.TeamVO;

import java.util.List;

/**
 * @author 木兔光太郎
 * @description 针对表【team(队伍表)】的数据库操作Service
 * @createDate 2024-08-16 11:04:46
 */
public interface TeamService extends IService<Team> {

    long addTeam(Team team, Userinfo loginUser);

    List<TeamVO> listTeams(TeamQueryDTO teamQueryDTO, boolean isAdmin);

    boolean updateTeam(TeamUpdateDTO teamUpdateDTO, Userinfo loginUser);

    boolean joinTeam(TeamJoinDTO teamJoinDTO, Userinfo loginUser);

    Boolean quitTeam(TeamQuitDTO teamQuitDTO, Userinfo loginUser);

    Boolean dissolveTeam(TeamQuitDTO teamQuitDTO, Userinfo loginUser);

    List<Team> getMyTeam(Userinfo loginUser);
}
